<script>
    layui.use('laypage', function(){
        var laypage = layui.laypage;
        laypage.render({
            elem: 'table-pager',
            theme: '#1E9FFF',
            layout: ['count', 'prev', 'page', 'next'],
            count: {{.total}}, //数据总数
            limit: {{.paginator.pagecount}},
            curr: {{.paginator.currpage}},
            jump: function(obj, first){
                if(!first){
                    window.location.href = {{.linkPrefix}} + "p=" + obj.curr;
                }
            }
        });

    });
</script>